local b = require('utils.buf')
local e = require('utils.editor')
local g = vim.g

local w = require('utils.win')
local m = require('utils.vim')

local M = {}

M.all_init = function()
    if b.get_filename(0) == '' then
        m.cmd("bd!") -- delete [No Name] buffer(even if it is modified)
    end

    local bs = g.divo_not_save_buffers
    if #bs > 0 then
        require('notify')('Modified buffer exists!')
        return
    end
    local k = "\\<c-w>" .. "o"  -- emulate ;o to max current win
    e.send_key(k)

    b.close_all() --may raise exception

    m.cmd("set signcolumn=auto:1")
end

return M
-- EOP
